-- GENERATED SPELL FOR [Crimson Inquisitor] --


function spell0_10426(pUnit, Event) --@Mana Burn,n/a--
pUnit:FullCastSpellOnTarget(15785,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10426', 2000, 1)
end

function spell1_10426(pUnit, Event) --@Mind Flay,n/a--
pUnit:FullCastSpellOnTarget(17165,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10426', 3000, 1)
end

function spell2_10426(pUnit, Event) --@Shackle Undead,n/a--
pUnit:FullCastSpellOnTarget(11444,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10426', 22000, 1)
end

function spell3_10426(pUnit, Event) --@Shadow Barrier,n/a--
pUnit:FullCastSpellOnTarget(17151,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10426', 515, 1)
end

function spell4_10426(pUnit, Event) --@Shadow Word: Pain,n/a--
pUnit:FullCastSpellOnTarget(17146,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_10426', 18000, 1)
end

function Sorts_10426(pUnit, Event)
local choix_sorts_10426 = math.random(0, 4)
if choix_sorts_10426 == 0 then
pUnit:RegisterEvent('spell0_10426', 1, 1)
end
if choix_sorts_10426 == 1 then
pUnit:RegisterEvent('spell1_10426', 1, 1)
end
if choix_sorts_10426 == 2 then
pUnit:RegisterEvent('spell2_10426', 1, 1)
end
if choix_sorts_10426 == 3 then
pUnit:RegisterEvent('spell3_10426', 1, 1)
end
if choix_sorts_10426 == 4 then
pUnit:RegisterEvent('spell4_10426', 1, 1)
end
end

function mob10426_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_10426', math.random(1500, 3000), 1)
end

function mob10426_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob10426_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob10426_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(10426, 1, 'mob10426_Action')
RegisterUnitEvent(10426, 2, 'mob10426_Leave')
RegisterUnitEvent(10426, 3, 'mob10426_Kill')
RegisterUnitEvent(10426, 4, 'mob10426_Die')
